<?php

namespace Agp\CoreBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;

/**
 * Agp\CoreBundle\Entity\ConfigBoleto
 *
 * @ORM\Table(name="config_boleto")
 * @ORM\Entity(repositoryClass="Agp\CoreBundle\Repository\ConfigBoletoRepository")
 */
class ConfigBoleto
{
    /**
     * @var integer $codConfigBoleto
     *
     * @ORM\Column(name="cod_config_boleto", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    protected $codConfigBoleto;
    
    /**
     * @ORM\ManyToOne(targetEntity="ContaBancaria", cascade={"persist"}, fetch="LAZY")
     * @ORM\JoinColumn(name="cod_conta_bancaria", referencedColumnName="cod_conta_bancaria", onDelete="cascade")
     * @var object
     */
    protected $contaBancaria;
    
    /**
     * @var string $descricao
     *
     * @ORM\Column(name="descricao", type="string", length=45)
     * @Assert\NotBlank()
     */
    protected $descricao;
    
    const TP_COBRANCA = 'Cobrança';
    const TP_VENDA = 'Venda';
    const TP_VENDA_ONLINE = 'Venda Online';
    /**
     * @var string $tipo
     *
     * @ORM\Column(name="tipo", type="string", length=45)
     * @Assert\NotBlank()
     */
    protected $tipo;
    
    /**
     * @ORM\ManyToOne(targetEntity="Agp\CoreBundle\Entity\Empresa", cascade={"persist"}, fetch="LAZY")
     * @ORM\JoinColumn(name="cod_empresa", referencedColumnName="cod_empresa", onDelete="cascade", nullable=true)
     * @var object
     */
    protected $empresa;
    
    /**
     * @ORM\Column(name="percentual_multa", type="float", nullable=true)
     * @Assert\NotBlank()
     * @var float
     */
    protected $percentualMulta;
    
     /**
     * @ORM\Column(name="percentual_juros", type="float", nullable=true)
     * @Assert\NotBlank()
     * @var float
     */
    protected $percentualJuros;
    
    /**
     * @ORM\Column(name="instrucao01", type="string", nullable=true)
     * @var string
     */
    protected $instrucao01;
    
    /**
     * @ORM\Column(name="instrucao02", type="string", nullable=true)
     * @var string
     */
    protected $instrucao02;
    
    /**
     * @ORM\Column(name="instrucao03", type="string", nullable=true)
     * @var string
     */
    protected $instrucao03;
    
    /**
     * @ORM\Column(name="instrucao04", type="string", nullable=true)
     * @var string
     */
    protected $instrucao04;
    
    /**
     * @ORM\Column(name="demonstrativo01", type="string", nullable=true)
     * @var string
     */
    protected $demonstrativo01;
    
    /**
     * @ORM\Column(name="demonstrativo02", type="string", nullable=true)
     * @var string
     */
    protected $demonstrativo02;
    
    /**
     * @ORM\Column(name="demonstrativo03", type="string", nullable=true)
     * @var string
     */
    protected $demonstrativo03;
    
    public function __construct() {
        $this->percentualMulta = 0;
        $this->percentualJuros = 0;
    }

        /**
     * Get codConfigBoleto
     *
     * @return integer 
     */
    public function getCodConfigBoleto()
    {
        return $this->codConfigBoleto;
    }
    
    public function getContaBancaria() {
        return $this->contaBancaria;
    }

    public function setContaBancaria($contaBancaria) {
        $this->contaBancaria = $contaBancaria;
    }

    
    public function getEmpresa() {
        return $this->empresa;
    }

    public function setEmpresa($empresa) {
        $this->empresa = $empresa;
    }
    
    public function getInstrucao01() {
        return $this->instrucao01;
    }

    public function setInstrucao01($instrucao01) {
        $this->instrucao01 = $instrucao01;
    }

    public function getInstrucao02() {
        return $this->instrucao02;
    }

    public function setInstrucao02($instrucao02) {
        $this->instrucao02 = $instrucao02;
    }

    public function getInstrucao03() {
        return $this->instrucao03;
    }

    public function setInstrucao03($instrucao03) {
        $this->instrucao03 = $instrucao03;
    }

    public function getInstrucao04() {
        return $this->instrucao04;
    }

    public function setInstrucao04($instrucao04) {
        $this->instrucao04 = $instrucao04;
    }

    public function getDemonstrativo01() {
        return $this->demonstrativo01;
    }

    public function setDemonstrativo01($demonstrativo01) {
        $this->demonstrativo01 = $demonstrativo01;
    }

    public function getDemonstrativo02() {
        return $this->demonstrativo02;
    }

    public function setDemonstrativo02($demonstrativo02) {
        $this->demonstrativo02 = $demonstrativo02;
    }

    public function getDemonstrativo03() {
        return $this->demonstrativo03;
    }

    public function setDemonstrativo03($demonstrativo03) {
        $this->demonstrativo03 = $demonstrativo03;
    }

    public function getDescricao() {
        return $this->descricao;
    }

    public function setDescricao($descricao) {
        $this->descricao = $descricao;
    }

    public function getTipo() {
        return $this->tipo;
    }

    public function setTipo($tipo) {
        $this->tipo = $tipo;
    }
    
    public function getPercentualMulta() {
        return $this->percentualMulta;
    }

    public function setPercentualMulta($percentualMulta) {
        $this->percentualMulta = $percentualMulta;
    }

    public function getPercentualJuros() {
        return $this->percentualJuros;
    }

    public function setPercentualJuros($percentualJuros) {
        $this->percentualJuros = $percentualJuros;
    }
 
    public static function getTipoList(){
        return array(self::TP_COBRANCA => self::TP_COBRANCA,
                     self::TP_VENDA => self::TP_VENDA,
                     self::TP_VENDA_ONLINE => self::TP_VENDA_ONLINE,);
    }

}
